package com.iris.live.services.data.repositories;

import com.iris.live.services.data.models.CrmAnswerModel;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

/**
 * Created by lusong on 2016/11/11.
 */
public interface CrmAnswerRepository extends JpaRepository<CrmAnswerModel,Integer>,JpaSpecificationExecutor<CrmAnswerModel> {

    @Query("select a from CrmAnswerModel a where a.stemId =?1")
    public List<CrmAnswerModel> queryAnswerByTopicId(Integer topicId);
}
